package com.littleken.foodieService;

import com.littleken.foodieCommon.Response.ServerResponse;
import com.littleken.foodiePojo.bo.InsertUserBO;
import com.littleken.foodiePojo.domain.UsersDO;
import com.littleken.foodiePojo.vo.UsersVO;

import java.util.List;

/*
 * Create by littleken on 2020/11/20 17:32
 */
public interface UsersService {

    List<UsersDO> userList();

    UsersDO getUser(String id);

    ServerResponse insertUser(InsertUserBO insertUserBO);

    String updateUser(UsersDO usersDO);

    ServerResponse deleteUser(String id);

    /**
     * 用户名是否存在
     *
     * @return 存在true 不存在false
     */
    boolean queryUserNameIsExist(String userName);

    /**
     * 用户登录
     * @param userName
     * @param password
     * @return
     */
    UsersVO userLogin(String userName, String password);
}
